//
//  ViewController.h
//  AWS Viewer
//
//  Created by Vincent de Smet on 9/16/13.
//  Copyright (c) 2013 TI Avans. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "CurrentAwsData.h"
#import "AFHTTPRequestOperation.h"

#define XIVELY_API_KEY @"P_btPeh4FcS-eBfr4NheLke2QvSSAKxmZ0hRQ2taTGlxYz0g"
#define XIVELY_FEED_ID  40053
#define DATASTREAM_COUNT 6

#define DS_AIRPRESSURE_INDEX 0
#define DS_HUMIDITY_INDEX 1
#define DS_RAINRATE_INDEX 2
#define DS_TEMP_INDEX 3
#define DS_WINDDIR_INDEX 4
#define DS_WINDSPEED_INDEX 5

@interface TableViewController : UITableViewController<UITableViewDataSource, UITableViewDelegate> {
    CurrentAwsData *currentAwsData;
    NSArray *tableData;
    int selectedTableIndex;
}
@property (strong, nonatomic) IBOutlet UITableView *tableView;

@property(nonatomic) CurrentAwsData *currentAwsData;

- (void) UpdateData;
- (void)operationFailed:(AFHTTPRequestOperation *)operation withError:(NSError *)error;
- (void)operationCompleted:(AFHTTPRequestOperation *)operation byResponse:(id)responseObject;

@end
